/* 
主样式表
设计原则：
1. 使用CSS变量统一主题色
2. 响应式布局适配不同设备
3. 现代化UI设计，包含阴影、圆角等效果
*/

:root {
    --primary-color: #2b3a67;       /* 深空蓝 */
    --hover-color: #384c87;         /* 悬停：银河蓝紫 */
    --secondary-color: #2196F3;
    --danger-color: #c0392b;        /* 警告红，稍深 */
    --warning-color: #e1b12c;       /* 星光金 */
    --background-color: #1b1f30;    /* 页面背景：深空黑蓝 */
    --text-color: #dcdde1;          /* 字体颜色：银河白灰 */
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    margin: 0;
    padding: 0;
    background-color: #f5f5f5;
}

.container {
            max-width: 1200px;
            margin: 0 auto;
            padding: 20px;
        }

.empty-message {
    color: #777;
    font-style: italic;
}

.file-actions {
    display: flex;
    gap: 8px;
    margin-top: 4px;
}

.file-input-btn {
    display: inline-block;
    padding: 10px 15px;
    background-color: var(--secondary-color);
    color: white;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s;
}
.file-input-btn:hover {
    background-color: #0b7dda;
}
.file-input-wrapper {
            position: relative;
            overflow: hidden;
            display: inline-block;
            width: 100%;
}

.file-item {
    display: flex;
    align-items: center;
    padding: 10px;
    margin-bottom: 8px;
    background-color: #f9f9f9;
    border-radius: 4px;
    transition: background-color 0.2s;
}
.file-item:hover {
    background-color: #f0f0f0;
}
.file-list {
    list-style: none;
    padding: 0;
}

.file-name {
            display: block;
            margin-top: 8px;
            font-style: italic;
            color: #666;
}
.file-name2 {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    padding-right: 15px;
}

.filter-button {
    padding: 8px 14px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 15px;
    font-weight: 500;
    color: #fff;
    background-image: linear-gradient(to bottom right, #2c3e50, #34495e);
    box-shadow: 0 2px 6px rgba(0,0,0,0.15);
    transition: all 0.25s ease;
}
.filter-button:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}
/* 下载按钮：星云绿 */
.filter-button.download {
    background-color: #2ecc71;
    background-image: linear-gradient(to bottom right, #27ae60, #2ecc71);
}
.filter-button.download:hover {
    background-color: #28a745;
    background-image: linear-gradient(to bottom right, #1f8c50, #28a745);
}
/* 归档按钮：恒星橙 */
.filter-button.archive {
    background-color: #f39c12;
    background-image: linear-gradient(to bottom right, #e67e22, #f39c12);
}
.filter-button.archive:hover {
    background-color: #d68910;
    background-image: linear-gradient(to bottom right, #ca6f1e, #d68910);
}
/* ✅ 批量删除按钮样式（高对比红） */
.filter-button.batch-delete {
    background-color: #e74c3c;
    background-image: linear-gradient(to bottom right, #c0392b, #e74c3c);
}
.filter-button.batch-delete:hover {
    background-color: #c0392b;
    background-image: linear-gradient(to bottom right, #96281b, #c0392b);
}
/* ✅ 单个删除按钮样式（也使用高对比红，或稍作变化以便区分） */
.filter-button.file-delete-btn {
    background-color: #e74c3c;
    background-image: linear-gradient(to bottom right, #c0392b, #e74c3c);
}
.filter-button.file-delete-btn:hover {
    background-color: #c0392b;
    background-image: linear-gradient(to bottom right, #96281b, #c0392b);
}

/* 筛选控制栏样式 */
.filter-controls {
    margin: 15px 0;
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
}

/* 智能动画控制 */
.filter-controls:not(.fast-filtering) .filter-select {
    transition: border-color 0.3s ease, transform 0.2s ease;
}
.filter-controls:not(.fast-filtering) .filter-select:hover {
    transform: translateY(-1px);
}
.filter-controls.fast-filtering .filter-select {
    transition: none !important;
}

.filter-select {
    padding: 8px;
    border-radius: 4px;
    border: 1px solid #ddd;
    background-color: white;
    transition: border-color 0.3s ease, transform 0.2s ease;
    will-change: transform;
}
.filter-select:hover {
    border-color: #4CAF50;
}

.form-group {
            display: flex;
            flex-direction: row;
            align-items: center;
            padding: 15px;
            background-color: #f8f9fa;
            border-radius: 8px;
            margin-right: 15px;
}

/* 页面布局主容器 */
.layout {
    display: flex;
    height: calc(100vh - 70px); /* 去除顶部导航高度 */
}

.loading-indicator {
    padding: 10px;
    margin: 10px 0;
    background-color: #f8f9fa;
    border-left: 4px solid #4CAF50;
    color: #333;
    font-weight: bold;
}
.loading-indicator i {
    margin-right: 8px;
}

/* 性能优化动画 */
.nav-links {
    margin: 0;
    padding: 12px 24px;
    border-bottom: 1px solid #1f2e3a;
    background: linear-gradient(to right, #0a1e2d, #10273a); /* 深空渐变 */
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    will-change: transform;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}
/* 基础样式（继承主配色） */
.nav-links a,
.nav-link {
    display: inline-block;
    padding: 10px 20px;
    margin-right: 10px;
    color: #f0f8ff;
    background-color: #1e3d59;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 500;
    letter-spacing: 0.5px;
    position: relative;
    overflow: hidden;
    backface-visibility: hidden;
    transform: translateZ(0);
    transition: 
        transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
        background-color 0.3s cubic-bezier(0.4, 0, 0.2, 1),
        box-shadow 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
/* 悬浮时星光感 */
.nav-link:hover,
.nav-links a:hover {
    background-color: #295778;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0, 128, 255, 0.3);
}
.nav-links a:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}
/* 活动状态优化 */
.nav-link.active {
    background-color: #6a89cc; /* 银河蓝紫 - 活动状态底色 */
    font-weight: bold;
    color: #ffffff; /* 活动状态文字颜色 */
    box-shadow: 0 2px 8px rgba(106, 137, 204, 0.5); /* 发光阴影效果 */
    border-bottom: 2px solid #9c88ff; /* 紫蓝底边线 - 增强感 */
}
.nav-link::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 12px;
    height: 12px;
    background: radial-gradient(circle, rgba(255,255,255,0.8), rgba(173,216,230,0.3), transparent);
    opacity: 0;
    border-radius: 50%;
    transform: translate(-50%, -50%) scale(0.6);
    transform-origin: center;
    pointer-events: none;
    transition: opacity 0.2s ease-out;
}
.nav-link:focus:not(:active)::after {
    animation: ripple-star 0.8s ease-out forwards;
}
.nav-links + .container {
  margin-top: 20px; /* 让导航栏与内容有距离 */
}

/* 页面过渡效果 */
.page-transition {
    animation: fadeIn 0.3s ease-out;
    will-change: opacity;
}

.params-grid {
            display: flex;
            flex-wrap: wrap;
            gap: 15px;
}

.param-input:focus {
            border-color: #4CAF50;
            outline: none;
            box-shadow: 0 0 0 2px rgba(76, 175, 80, 0.2);
}

.progress-bar {
  width: 100%;
  height: 20px;
  border-radius: 10px;
  appearance: none;
  -webkit-appearance: none;
  background-color: #2c2f48; /* 深夜蓝 */
  overflow: hidden;
  margin-bottom: 10px;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.4);
}
.progress-bar::-webkit-progress-bar {
  background-color: #2c2f48;
  border-radius: 10px;
}
.progress-bar::-webkit-progress-value {
  background-color: #6a89cc; /* 银河蓝紫 */
  border-radius: 10px;
  transition: width 0.4s ease-in-out;
}
.progress-bar::-moz-progress-bar {
  background-color: #6a89cc;
  border-radius: 10px;
}
/* 容器外观：暗背景 + 光影效果 */
.progress-container {
  margin-top: 20px;
  background: #1b1f30; /* 深空背景 */
  border-radius: 8px;
  padding: 16px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.6);
  font-size: 15px;
  color: #dcdde1; /* 银河白灰 */
}
/* 进度条头部：图标/名称与右侧进度百分比 */
.progress-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: nowrap;
  margin-bottom: 12px;
}
.progress-left {
  display: flex;
  align-items: center;
  gap: 10px;
  white-space: nowrap;
  color: #f5f6fa; /* 明亮星光色 */
  font-weight: 600;
}
.progress-right {
  white-space: nowrap;
  font-weight: 500;
  color: #9c88ff; /* 紫蓝 - 亮进度文字 */
}

.spinner {
  width: 16px;
  height: 16px;
  border: 3px solid #ccc;
  border-top: 3px solid #007bff;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}


label {
            margin-right: 10px;
            font-weight: 600;
            color: #555;
            font-size: 16px;
            white-space: nowrap;
}


#file-info,
#file-progress {
  font-size: 13px;
  color: #666;
  margin-top: 4px;
}

#parameters-container {
            padding: 15px;
            background-color: white;
            border-radius: 8px;
            box-shadow: 0 2px 6px rgba(0,0,0,0.1);
            margin-bottom: 20px;
}


@keyframes fadeIn {
    from { opacity: 0.9; transform: translateY(5px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes ripple {
    0% {
        transform: scale(0.1, 0.1) translate(-50%);
        opacity: 0.5;
    }
    100% {
        transform: scale(15, 15) translate(-50%);
        opacity: 0;
    }
}

@keyframes ripple-star {
    0% {
        opacity: 0.9;
        transform: translate(-50%, -50%) scale(0.5);
    }
    50% {
        opacity: 0.6;
        transform: translate(-50%, -50%) scale(2.5);
    }
    100% {
        opacity: 0;
        transform: translate(-50%, -50%) scale(4);
    }
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* 响应式设计优化 */
@media (max-width: 768px) {
    .nav-links {
        flex-direction: column;
        gap: 8px;
    }
    
    .nav-link {
        width: 100%;
        text-align: center;
        transform: none !important;
    }

    .filter-controls {
        flex-direction: column;
        align-items: stretch;
    }
    
    .filter-select {
        width: 100%;
    }
}
